/****************************************************************
 *  This file created by writerB.php on 03/20/2007 at 23:03:46  *
 ****************************************************************
 *  writerB.php created by Tonk (tonk@ctonk.com) in 2007        *
 ****************************************************************
 *                 General Document Information
 *
 *  File Name: board.h
 *  Class Name: Board
 *  Parent Classes: none
 *  Data members: 4
 *  Notes:
 ****************************************************************/

#ifndef __H_BOARD
#define __H_BOARD

#include <iostream>
#include <vector>
#include "note.h"



class Board {
	protected:
		// Protected data...
		int			_BoardID;	// Holds a unique value for every instantiation.
		unsigned	_number;
		unsigned	_level;
		std::string	_name;
		std::string	_file;
		std::vector< Note* >	_notes;

		// Protected methods...
		void	setBoardID( const int& BoardID );

	public:
		// Constructors...
		Board();
		Board( const Board& );	// Doesn't change _BoardID
		~Board();

		// Operators...
		Board& operator = ( const Board& );			// Doesn't change _BoardID
		bool operator == ( const Board& ) const;	// Compares _number
		bool operator != ( const Board& ) const;	// Compares _number
		bool operator < ( const Board& ) const;		// Compares _number
		bool operator > ( const Board& ) const;		// Compares _number

		// Public accessor methods...
		int			getBoardID( void ) const;
		void		setNumber( const unsigned& number );
		unsigned	getNumber( void ) const;
		void		setLevel( const unsigned& level );
		unsigned	getLevel( void ) const;
		void		setName( const std::string& name );	// Sets _name and _file
		std::string	getName( void ) const;
		std::string	getFile( void ) const;
		std::vector< Note* >&	getNotes( void );

		// General methods...
		Note*	addNote( void );
		void	load( void );
		void	save( void );
		void	initialize( const unsigned& number, const unsigned& level, const std::string& name );

		// Static members and methods...
		static unsigned boardIndex;	// Used to create a unique id for every Board object
		static unsigned numBoards;	// Keeps track of the total number of Board objects
};

// Associated operators...
std::ostream& operator << ( std::ostream&, Board& );
std::ostream& operator << ( std::ostream&, Board* );



#endif // __H_BOARD
